package net.kts.subskill.airport;

import net.kts.main.R;
import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.view.View.OnClickListener;
import android.widget.Button;

/*
 * 인천공항 메인 
 */
public class IncheonAirport extends Activity {
	
	private String[] strArray = {
			"IncheonAirport"
	};
	private int[] id3FArray = {
			R.drawable.airport_incheon_sub_guide01
	};
	private int[] id1FArray = {
			R.drawable.airport_incheon_sub_guide03
	};
	private int[] idTrafficArray = {
			R.drawable.airport_incheon_taxi
	};
	
	// 갤러리 액티비티 실행
	public void startGallery(int position, int[] idArray){
		Intent intent = new Intent(IncheonAirport.this, LocalGalleryDetail.class);
		intent.putExtra("position", position);
		intent.putExtra("idArray", idArray);
		intent.putExtra("strArray", strArray);
		startActivity(intent);
	}
	
    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.airport_incheon_main);

        // 3층 출발
		Button btnGOne = (Button)findViewById(R.id.btn_get3F);
		btnGOne.setOnClickListener(new OnClickListener() {
			@Override
			public void onClick(View v) {
				startGallery(0, id3FArray);
//				Intent intent = new Intent(IncheonAirport.this, LocalGalleryDetail.class);
//				intent.putExtra("position", 0);
//				intent.putExtra("idArray", id3FArray);
//				startActivity(intent);
			}
		});
		
		// 1층 도착
		Button btnGTwo = (Button)findViewById(R.id.btn_get1F);
		btnGTwo.setOnClickListener(new OnClickListener() {
			@Override
			public void onClick(View v) {
				startGallery(0, id1FArray);
			}
		});
		
		// 교통
		Button btnGThree = (Button)findViewById(R.id.btn_getTraffic);
		btnGThree.setOnClickListener(new OnClickListener() {
			@Override
			public void onClick(View v) {
				startGallery(0, idTrafficArray);
			}
		});
        
    }
}
